Error CS1733 - Expected Expression

When I generate CRUD pages, or Grid pages, I'm getting a method call with empty parameter values for every page and I'm stumped as to what's causing it.

I created some pages against the Northwind DB (which I installed on the same server) and the code is generated without parameters. If I remove the parameter calls from my code, it code runs fine.

var simpletestSqlGetOrganisationsResult = await SimpletestSql.GetOrganisations(int.Parse($"{}"), int.Parse($"{}"));

(edit) I'm also getting this format:

var simpletestSqlGetDocumentQueuesResult = await SimpletestSql.GetDocumentQueues($"[object Object][object Object]", int.Parse($"{}"), int.Parse($"{}"));

From Northwind

var nwtestGetCustomersResult = await Nwtest.GetCustomers();


Its not a good fix but if you go and edit something on that page in Radzen IDE the parameters will be populated if i rembeber correctly. Iv got the same "error" a while ago

That did indeed solve the problem, although the parameters were removed rather than populated - nice catch and thank you!

I agree - it's not a great fix though. Even with just three tables I've got nine pages that need to be edited (or sets of code that need to be amended).

Radzen Team - does this need a bug report filed somewhere (where?) or do you pick up these issues from the forum?


Hi @Gordon,

If you have Radzen subscription you can send us an example application demonstrating the problem at to debug it.

Just a trial at this stage I'm afraid.

I'm afraid that we are not sure how to reproduce this. All applications (including such from Northwind database) in our test environment can be scaffolded normally and the code generated on run works as expected.

Can I email you a sample sql script to generate a table (it's small - just three fields), but it's happening on every table I have. They're very similar in nature. DB is sql on Azure, tables are a non-DBO schema.

Later today I can probably hook up to an on-prem SQL db to see if the same happens.

As i said iv got this too in a project. Maybe i can send my testapplication and you can debug it? I have a License aswell. Just to adress the problem.

@Gottegubben, yes send us the project and details how to reproduce it.

1 Like

Okey so i found a pattern on the problem and when its happening. Should i write a new post just like a did another bug report yesterday?

You can post it here

So recently i found a bug when CRUD pages are generated from a datasoruce. There is sometimes unpopulated parameters in the datasource service functions called in the Load function on the generated CRUD page. This only occurs if there is more then one service call.

How to reproduce:

Create a new MS SQL Server datasource with the "Create sample Schema" button.

Check the "Generete pages for CRUD operations" checkbox. then click Finish

Now browse to EditOrderDetail.razor.designer.cs file and open it in Visual Studio.

Here we can see that there is unpopulated parameters in the calls med after the first call. The first call is always correct. That we can see in the EditOrder.razor.designer.cs file. It only has one call and it is generated correctly.


If you go in Radzen IDE and go to a page that is generated wrong and click on the load handler and click done. The parameters are remove for that page.


If you go to the datasource you just created and click "infer schema" and press finish without checking the "Generate pages for CRUD operations" checkbox. The result is the same as saving the load handler as said above but the parameters are removed for all pages.

Try to run the application from Radzen - the app full code will be generated only on run.

But if a developer run the project from Visual Studio? And to run the app from Radzen to "fix" this problem isnt a "fix" imo. Why does the bug occur in first place?

@Gottegubben we will review what's causing this wrong code generation however to make sure that you have the correct code generated you will need to run the application from Radzen. At the moment because of the designer there are partial code generations however we cannot run full application code generation since it will be very slow.

I can confirm I run the app from Visual Studio too - as it's easier to see code problems from the VS build.

@Gottegubben nice find!

@enchev nice to see there's a workaround that doesn't involve having to manually edit the pages.

Thanks both of you for your help.


In Radzen 3.0 you will always work with the latest code btw. No need to run + you can edit the code directly.

1 Like

I am so looking forward to that !

1 Like